package com.cn.customer.housekeeping.housekeepingc.util;


import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.os.Vibrator;

import com.cn.customer.housekeeping.housekeepingc.bridge.BridgeFactory;
import com.cn.customer.housekeeping.housekeepingc.bridge.Bridges;
import com.cn.customer.housekeeping.housekeepingc.bridge.cache.sharePref.EBSharedPrefManager;


public class MyTokenOutReceive extends BroadcastReceiver {
     Vibrator vibrator;
    Context contexts;
    public MyTokenOutReceive(){

    }
    public MyTokenOutReceive(Context context){
        this.contexts=context;
    }

    @Override
    public void onReceive(Context context, Intent intent) {
        EBSharedPrefManager manager = BridgeFactory.getBridge(Bridges.SHARED_PREFERENCE);
//        String phone = manager.getKDPreferenceUserInfo().getString(EBSharedPrefUser.phone, "");
//        String headpic = manager.getKDPreferenceUserInfo().getString(EBSharedPrefUser.headpic, "");
//        manager.getKDPreferenceUserInfo().clear();
//        manager.getKDPreferenceUserInfo().saveString(EBSharedPrefUser.phone, phone);
//        manager.getKDPreferenceUserInfo().saveString(EBSharedPrefUser.headpic, headpic);
        ToastUtil.makeText(context,"token过期,请重新登录");
//        NavUtils.gotoLoginCodeAgainActivity(context);
    }
}
